package org.openotdr.server;

import com.miyake.rest.LicenseType;
import com.miyake.rest.ServiceType;
import com.miyake.rest.WebServiceProperty;

public abstract class PropertyBuilder {
    protected abstract String getDescription();
    protected abstract String getServiceName();
    protected abstract String getServiceUrl();
    protected abstract ServiceType getServiceType();
    protected abstract String getVersion();
    
    WebServiceProperty prop = new WebServiceProperty();
    public PropertyBuilder() {
        prop.setCategory("OTDR");
        prop.setCompanyUrl("http://openotdr.appspot.com/");
        prop.setDescription(getDescription());
        prop.setLicenseType(LicenseType.Free);
        prop.setProvider("OpenOtdrProject");
        prop.setServiceName(getServiceName());
        prop.setServiceUrl(getServiceUrl());
        prop.setServiceType(getServiceType());
        prop.setVersion(getVersion());   
    }
    
    public WebServiceProperty getProperty() {
        return prop;
    }
}
